1. Field of the Invention
The present invention relates to a method for determining coordinates of a circumscribed rectangular frame of each character for use in an optical character reader, more particularly, to a method for determining coordinates of a circumscribed rectangular frame for enclosing each character upon processing character images in an optical character reader.
2. Description of Related Art
In a conventional optical character reader, in order to recognize characters which are typed along respective lines parallel to the horizontal direction in a recognition area, it is necessary to determine coordinates of a circumscribed rectangular frame for enclosing each character from binary image data read by an image scanner, and to determine respective lines of character images based on the determined coordinates of the circumscribed rectangular frames of respective characters. The circumscribed rectangular frame of each character has a longitudinal length and a transverse width which fall in predetermined ranges respectively, and is referred to as a character rectangle hereinafter.
As a method for determining the coordinates of the character rectangles from the binary image data, conventionally, there has been used a method for determining the coordinates thereof by scanning plural black pixels connected to each other (referred to connected components hereinafter) such as the CLAB algorithm (the algorithm for labeling the connected components of black pixels) which is provided in the Subroutine Package for Image Data Enhancement and Recognition (SPIDER) developed by the Nippon Kohgyo Gijutsuin.
However, in the conventional method for determining the coordinates of the character rectangles by scanning connected components of black pixels, there is such a problem that the processing time thereof is relatively long since it is necessary to judge whether or not there is a connected component to be connected to each black pixel.
In a conventional optical character reader, there has been used a method for determining character portions using the method for labeling the connected components of black pixels. In this case, in order to overcome the above-mentioned problem of the processing time, it has been considered that compressed image data are used and there is used a hard system provided for only the above-mentioned process. However, labeling the connected components of black pixels using the compressed image data leads to missing of information of the original image. Particularly, it may be difficult to correctly determine the character rectangles since it may be judged that a black pixel is connected to a character rectangle close thereto even though the black pixel is not connected thereto. Further, when there is used the hard system provided for only determining the character rectangles, there is such a problem that the cost of the whole system including the hard system becomes relatively high.